<?php

/**
* @copyright   (C) 2010 iJoomla, Inc. - All rights reserved.
* @license  GNU General Public License, version 2 (http://www.gnu.org/licenses/gpl-2.0.html) 
* @author  iJoomla.com webmaster@ijoomla.com
* @url   http://www.ijoomla.com/licensing/
* the PHP code portions are distributed under the GPL license. If not otherwise stated, all images, manuals, cascading style sheets, and included JavaScript  
* are NOT GPL, and are released under the IJOOMLA Proprietary Use License v1.0 
* More info at http://www.ijoomla.com/licensing/
*/

	defined('_JEXEC') or die('Restricted access');

	$show_result = "0";
	$email_send = "0";
	$email_send_to = "";
	
	if($this->values != ""){
		$show_result = $this->values["0"]["show_result"];
		$email_send = $this->values["0"]["email_send"];
		$email_send_to = $this->values["0"]["email_send_to"];
	}
?>

<table class="adminform">
	<tr>
		<td align="left" valign="middle" width="15%" nowrap="nowrap">
			<b><?php echo JText::_("COM_SURVEYS_SHOW_SURVEY_RESULT"); ?> :</b>
		</td>
		<td>
			<table>
				<tr>
					<td>
						<table>
							<tr>
								<td>
									<input name="show_result" type="radio" value="1" <?php if ($show_result==1) echo "checked=\"checked\""?> />
								</td>
								<td>
									<?php echo JText::_("JYES");?>
								</td>	
							</tr>
						</table>		
					</td>
					<td>
						<table>
							<tr>
								<td>
									<input name="show_result" type="radio" value="0" <?php if ($show_result==0) echo "checked=\"checked\""?>/>
								</td>
								<td>
									<?php echo JText::_("JNO"); ?>
								</td>
							</tr>
						</table>
					</td>			
				</tr>
			</table>
		</td>
	</tr>
	<tr>
		<td width="15%" nowrap="nowrap">
			<b><?php echo JText::_("COM_SURVEYS_SEND_EMAIL"); ?> :</b>
		</td>
		<td>
			<select name="email_send">
				<option <?php if($email_send == '0') { echo 'selected="selected"'; }?> value="0"><?php echo JText::_("COM_SURVEYS_GLOBAL"); ?></option>
				<option  <?php if($email_send == '1') { echo 'selected="selected"'; }?> value="1"><?php echo JText::_("JYES"); ?></option>
				<option <?php if($email_send == '2') { echo 'selected="selected"'; }?> value="2"><?php echo JText::_("JNO"); ?></option>
			</select>
		</td>
	</tr>
	<tr>
		<td width="15%" nowrap="nowrap">
			<b><?php echo JText::_("COM_SURVEYS_SEND_EMAIL_TO"); ?> :</b>
		</td>
		<td>
			<input type="text" name="email_send_to" value="<?php echo $email_send_to; ?>" />
		</td>
	</tr>	
</table>	